/* 全局样式 */
:root {
    --primary-color: #00ffff;
    --secondary-color: #00ff00;
    --dark-bg: #0f0c29;
    --grid-size: 30px;
    --grid-color: rgba(0, 255, 255, 0.03);
    --grid-border: rgba(0, 255, 255, 0.05);
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* 科技感背景 */
.tech-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.tech-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(90deg, transparent calc(var(--grid-size) - 1px), var(--grid-border) calc(var(--grid-size) - 1px), var(--grid-border) var(--grid-size)),
        linear-gradient(0deg, transparent calc(var(--grid-size) - 1px), var(--grid-border) calc(var(--grid-size) - 1px), var(--grid-border) var(--grid-size));
    background-size: var(--grid-size) var(--grid-size);
    animation: gridMove 30s linear infinite;
}

.tech-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, 
        rgba(15, 12, 41, 0) 0%, 
        rgba(15, 12, 41, 0.2) 40%, 
        rgba(15, 12, 41, 0.7) 80%, 
        rgba(15, 12, 41, 0.9) 100%
    );
}

.data-streams {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background: 
        repeating-linear-gradient(45deg,
            transparent 0%,
            transparent 98%,
            var(--grid-color) 98%,
            var(--grid-color) 100%
        ),
        repeating-linear-gradient(-45deg,
            transparent 0%,
            transparent 98%,
            var(--grid-color) 98%,
            var(--grid-color) 100%
        );
    background-size: var(--grid-size) var(--grid-size);
    transform-origin: center;
    animation: rotateGrid 120s linear infinite;
}

@keyframes gridMove {
    0% { background-position: 0 0; }
    100% { background-position: var(--grid-size) var(--grid-size); }
}

@keyframes rotateGrid {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.floating-servers {
    position: absolute;
    width: 100%;
    height: 100%;
}

.floating-servers i {
    position: absolute;
    color: rgba(0, 255, 255, 0.1);
    animation: float 15s infinite;
    text-shadow: 0 0 10px var(--primary-color);
    opacity: 0.5;
    transition: all 0.5s ease;
}

.floating-servers i:hover {
    color: rgba(0, 255, 255, 0.3);
    text-shadow: 0 0 20px var(--primary-color);
    opacity: 1;
}

.floating-servers i:nth-child(1) { font-size: 40px; top: 10%; left: 10%; animation-delay: 0s; }
.floating-servers i:nth-child(2) { font-size: 30px; top: 20%; right: 20%; animation-delay: 2s; }
.floating-servers i:nth-child(3) { font-size: 50px; bottom: 30%; left: 30%; animation-delay: 4s; }
.floating-servers i:nth-child(4) { font-size: 35px; bottom: 10%; right: 10%; animation-delay: 6s; }

/* 登录容器 */
.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.login-box {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 30px rgba(0, 255, 255, 0.1);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
    color: #fff;
}

.login-header i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    animation: glow 2s infinite;
}

@keyframes glow {
    0%, 100% { text-shadow: 0 0 10px var(--primary-color); }
    50% { text-shadow: 0 0 20px var(--primary-color), 0 0 30px var(--secondary-color); }
}

.login-header h1 {
    font-size: 1.8rem;
    margin: 10px 0;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* 切换按钮 */
.toggle-container {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
    gap: 10px;
}

.toggle-btn {
    background: none;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    padding: 8px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.toggle-btn.active {
    background: var(--primary-color);
    color: #000;
}

/* 表单样式 */
.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

.form-group {
    margin-bottom: 20px;
}

.input-group {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
}

.input-group-text {
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: var(--primary-color);
}

.form-control {
    background: transparent;
    border: none;
    color: #fff;
    padding: 12px;
}

.form-control:focus {
    background: transparent;
    box-shadow: none;
    border: none;
    color: #fff;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.btn-login {
    width: 100%;
    padding: 12px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border: none;
    border-radius: 5px;
    color: #000;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.3);
}

.error-message {
    color: #ff4444;
    text-align: center;
    margin-top: 10px;
    font-size: 0.9rem;
    min-height: 20px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
} 